{% extends 'layouts/base.html' %}
{% block content %}

<div class="row">
    <div class="col-xs-12">
        <!-- PAGE CONTENT BEGINS -->
        <div class="row">
            <div class="col-xs-12">
                <form action="{{ url('backend/order/batchappointment') }}" method="post">
                    <table id="sample-table-1" class="table table-striped table-bordered table-hover">
                        <thead>
                        <tr>
                            <th class="center">
                                <label class="position-relative">
                                    <input type="checkbox" class="ace" />
                                    <span class="lbl"></span>
                                </label>
                            </th>
                            <th><a href="{{ url('curr_url', {'sort':'id'})}}">id</a></th>
                            <th><a href="{{ url('curr_url', {'sort':'service_id'})}}">业务类型</a></th>
                            <th><a href="{{ url('curr_url', {'sort':'client_name'})}}">预约人</a></th>
                            <th><a href="{{ url('curr_url', {'sort':'client_phone'})}}">联系电话</a></th>
                            <th><a href="{{ url('curr_url', {'sort':'appointment_date'})}}">预约时间</a></th>
                            <th><a href="{{ url('curr_url', {'sort':'appointment_address'})}}">预约地址</a></th>
                            <th><a href="{{ url('curr_url', {'sort':'appointment_detail'})}}">详细信息</a></th>
                            <th><a>操作</a></th>
                        </tr>
                        </thead>

                        <tbody>


                        {% for row in result %}
                        <tr>
                            <td class="center">
                                <label class="position-relative">
                                    <input name="dels[]" value="{{row.appointment_id}}" type="checkbox" class="ace" />
                                    <span class="lbl"></span>
                                </label>
                            </td>

                            <td> {{row.appointment_id}} </td>
                            <td> {{row.service_type}} </td>
                            <td> {{row.client_name}} </td>
                            <td> {{row.client_phone}} </td>
                            <td> {{row.appointment_date|date("Y-m-d")}} </td>
                            <td> {{row.appointment_address}} </td>
                            <td> {{row.appointment_detail}} </td>

                            <td>
                                <div class="hidden-sm hidden-xs btn-group">
                                    <a class="btn btn-xs btn-danger adel" href="{{url('backend/order/delappointment', {'id':row.appointment_id})}}">
                                        <i class="ace-icon fa fa-trash-o bigger-120"></i>
                                    </a>
                                </div>
                            </td>
                        </tr>
                        {% endfor %}
                        </tbody>
                    </table>

                    <div class="row">
                        <div class="col-xs-6"><button type="submit" class="btn btn-white btn-warning btn-bold"><i class="ace-icon fa fa-trash-o bigger-120 orange"></i>批量删除</button></div>
                        <div class="col-xs-6">
                            <div class="dataTables_paginate paging_bootstrap">
                                <ul class="pagination">
                                    {{pagestr | raw}}
                                </ul>
                            </div>
                        </div>
                    </div>
                </form>

            </div><!-- /.span -->
        </div><!-- /.row -->


    </div>
</div>

<!-- inline scripts related to this page -->
{% endblock %}
